From 5536a63b3c51b9c6c31df73083eb686cbc8ee0b9 Mon Sep 17 00:00:00 2001 From: Boyuan Yang Date: Tue, 2 Feb 2021 11:42:24 -0500 Subject: [PATCH] Prepare new upload. --- debian/changelog | 8 +++++--- debian/control | 3 +-- debian/rules | 27 ++++++++++++++++++++------- 3 files changed, 26 insertions(+), 12 deletions(-) diff --git a/debian/changelog b/debian/changelog index 1d84228..9332a24 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,11 @@ opencc (1.1.1+git20200624+ds2-5) unstable; urgency=medium - * debian/rules: Enable dh_doxygen integration. + * debian/rules: Rewrite to support build profile. + * debian/rules: Enable dh_doxygen when building docs. * Drop unnecessary build dependencies. (Closes: #981606) - * debian/control: Drop build-dependency on libjs-jquery, let - dh_doxygen handle it. + * debian/control: Mark build-dependency doxygen as . + * debian/control: Drop build-dependency on libjs-jquery. Let + doxygen handle it. * debian/control: Drop build-dependency on graphviz. Doxyfile did not enable HAVE_DOT. * debian/control: Drop build-dependency on dartz. Currently opencc diff --git a/debian/control b/debian/control index cbfb2e8..2eadce4 100644 --- a/debian/control +++ b/debian/control @@ -12,7 +12,7 @@ Build-Depends: cmake, darts, debhelper-compat (= 13), - doxygen, + doxygen , libmarisa-dev, libtclap-dev, python3:any, @@ -73,7 +73,6 @@ Multi-Arch: foreign Section: doc Depends: ${misc:Depends}, - libjs-jquery, Description: simplified-traditional Chinese conversion library - document opencc is a library for converting character between traditional Chinese and simplified Chinese. diff --git a/debian/rules b/debian/rules index 70acce0..9542519 100755 --- a/debian/rules +++ b/debian/rules @@ -9,19 +9,32 @@ export DEB_BUILD_MAINT_OPTIONS = hardening=+all include /usr/share/dpkg/architecture.mk %: - dh $@ --buildsystem=cmake --with pkgkde_symbolshelper,doxygen + dh $@ --buildsystem=cmake --with pkgkde_symbolshelper + +BUILD_OPTIONS = \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_INSTALL_LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/ \ + -DCMAKE_BUILD_TYPE=Release \ + -DBUILD_BUNDLED_LIBMARISA=OFF + +ifeq (,$(filter nodoc,$(DEB_BUILD_OPTIONS))) +BUILD_OPTIONS += -DBUILD_DOCUMENTATION=ON +else +BUILD_OPTIONS += -DBUILD_DOCUMENTATION=OFF +endif + override_dh_auto_configure: - dh_auto_configure -- \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_INSTALL_LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/ \ - -DCMAKE_BUILD_TYPE=Release \ - -DBUILD_DOCUMENTATION=ON \ - -DBUILD_BUNDLED_LIBMARISA=OFF + dh_auto_configure -- $(BUILD_OPTIONS) execute_after_dh_auto_clean: find . -name *.pyc -delete +execute_after_dh_installdocs-indep: +ifeq (,$(findstring nodoc,$(DEB_BUILD_PROFILES))) + dh_doxygen --indep +endif + override_dh_installdocs: dh_installdocs -plibopencc-doc --doc-main-package=opencc dh_installdocs --remaining-packages -- 2.30.2